Linux FDS Scripts Readme
========================

Since Version 1.5 of scripts.dll, we support the Free Linux Dedicated Server. This is done though a
binary patch written by Datalore. Thanks to him for his awesome work.

There are no changes needed to make your mod/map work for the LFDS. It all works out of the box. The
serveradmin has to install the binary patch, and use the proper scripts.so.

As of version 1.7.1, there is support for loading the bhs.so file if it is present. On redhat7, it loads bhs.so and calls its init function.
On redhat 8, it loads bhs8.so and calls its init function.

Installation
============
Run the linux_renegade_binary_scripts_patch.exe and choose your renegade
binary. There are two versions of the LFDS. One is compiled for Redhat 7.3,
the other one for Redhat 8.0. The program will automatically patch your
binary. If you dont have a windows machine to run it on, try running it under WINE.

The patch makes 2 changes.
Firstly, it removes the read-only flag from the code segment in the ELF header so that the runtime patch can patch the code.
And secondly, it changes an entry in the LFDS import table so that our CXIME function gets called instead of ctime, allowing
us to install the runtime patches.

Next, you need the proper scripts linked libary. Depending on your version of
the FDS, you either take scripts-RH7.so or scripts-RH8.so. It is important
that you choose the right scripts.so, because each libary is specifically
compiled for either gcc 2.95 (Redhat 7) or gcc 3.2 (Redhat 8). Running the RH8
.so on a RH7 FDS will make the server crash.

Once you have both the binary patched and the proper .so in your renegade
directory you can start your server. The best way to do is to run mac's
renegade wrapper that also provides Remote Administratoin capability. As of
version 0.3, the wrapper automatically loads automatically the .so file, and
starts renegade. You can get version 0.3 of the wrapper at
http://www.brenbot.com/wrapper

If you prefer to do it manually, here's how:
Use this template for a little shell script. Be sure to adjust your name
of the linked libary, and the name of the renegade executable.

#/usr/bin/sh

export LD_PRELOAD=./scriptsRH8.so
./renegade
export LD_PRELOAD=

RenAlert Support & Mods Support
===============================

The version 1.5 scripts incoperate changes to the function prototypes that are
currently incompatible with Renegade Alert. The Renegade Alert Team has to
update the modification to support scripts 1.5. However, look out for a
special RenAlert Linux FDS that uses version 1.4 as a base. It works with
RenAlert.

However, CNC Reborn should run on scripts 1.5 without problems.

Developers
==========

If you want to compile your scripts package for Linux, there are 2 compile
scripts included in this package. compile-RH7.sh and compile-RH8.sh. To
compile your scripts for a Redhat7 FDS, use compile-RH7.sh. To do that, your
gcc must be version 2.95! Compiling a RH7 scripts on gcc 3.2 (most recent
distribution use gcc 3.X) will not work!

If compiling a RH8 script, use the included compile-RH8.sh. You must have 
gcc 3.2 to do that. Other than that, there shouldn't be much problems to compile your
scripts under Linux. Just don't use anything windows specifics in your code..

If you do not have a gcc 2.95 available and want to compile your scripts
for Redhat7, you can try to contact mac. He can probably compile your scripts
on Redhat7.

Credits
========
orginal idea: mac & jonwil
coding & patching: datalore
documentation: mac
